package com.wirelesstransfer.AsyncTasks;

import android.os.AsyncTask;
import android.widget.ArrayAdapter;


public class UpdateStatusList extends AsyncTask<String, String, String> {

	ArrayAdapter<String> hosts;	

	public UpdateStatusList(){
		hosts = AsyncTaskElements.hosts;
	}
	
	
	protected String doInBackground(String... ips) {
		publishProgress(ips[0]);

		return null;
	}

	protected void onProgressUpdate(String... values){
		System.err.println("updating Status ListView");
		if(hosts.getPosition(values[0]) >= 0)
			hosts.remove(values[0]);
		else
			hosts.add(values[0]);

	}

}
